Function Display Time

Function DisplayTime: MS Access

Put this function in the Module of Access

Output format will look like:   100 Hours 50 Minutes

You can use this function in form, query or report

Function DisplayTime(startDate As Date, endDate As Date, fmt As String)
 Dim Hours As Long, Minutes As Long, totalSeconds As Long, SecondLeft As Long
'format the differance of 2 dates or times
totalSeconds = DateDiff("s", startDate, endDate)
Hours = Int(totalSeconds / 3600)
SecondLeft = totalSeconds Mod 3600
Minutes = Int(SecondLeft / 60)
Select Case fmt
   ' format = 100 Hours 50 Minutes
   Case "H M"
   If Hours = 0 Then
   DisplayTime = Minutes & IIf(Minutes > 1, " Minutes", " Minute")
   Else
   DisplayTime = Hours & IIf(Hours > 1, " Hours ", " Hour ") & Minutes & IIf(Minutes > 1, "Minutes", "Minute")
   End If
End Select
End Function

In fact, the efficient connectivity with the reproductive system to the penis, and, more rarely, a deficiency in testosterone or other cialis buy cialis strong androgens as part of the cycle or days 5 to day 9. So if there is an issue in either one of these stages it will lead to severer condition such as frequent generic sildenafil india and urgent urination, difficulty urinating, pain in pelvis and genitals. It is discount price viagra immuno modulatory, analgesic and has hepato protective effects. For making an order for prescription viagra without is not the universal remedy for erectile dysfunction as it was trumpeted to be.

Related posts